<template>
  <div>
    <el-form-item label="上传地址">
      <el-input placeholder="请输入上传地址" v-model="localData.action" />
    </el-form-item>
  </div>
</template>

<script>
export default {
  name: 'ImageUploadConfig',
  props: {
    data: {
      type: Object,
      default: () => {}
    }
  },
  data() {
    return {
      localData: {}
    }
  },
  watch: {
    data: {
      handler(newVal) {
        if (newVal) {
          this.localData = newVal
        }
      },
      deep: true,
      immediate: true
    },
    localData: {
      handler(newVal) {
        this.$emit('update:data', newVal)
      },
      deep: true
    }
  }
}
</script>

<style scoped></style>
